package cn.zjutleo.village_server.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.util.Date;

/**
 * @author : Qin Zhenghan
 * @date : Created in 2021/9/2
 * @description: 消息DTO
 */
@ApiModel(value="消息数据交互类")
@Data
public class MessageDto {

    /**
     * 发送者id
     */
    @ApiModelProperty(value="发送者id")
    private Integer senderId;

    /**
     * 接收者id
     */
    @ApiModelProperty(value="接收者id")
    @NotNull(message = "接受者id不可为空！")
    private Integer receiveId;

    /**
     * 消息标题
     */
    @ApiModelProperty(value="消息标题")
    @NotEmpty(message = "消息标题不可为空！")
    private String title;

    /**
     * 消息内容
     */
    @ApiModelProperty(value="消息内容")
    @NotEmpty(message = "消息内容不可为空！")
    private String content;

}
